home *** CD-ROM | disk | FTP | other *** search
/ Language/OS - Multiplatform Resource Library / LANGUAGE OS.iso / pcl / sptmbr11.lha / instructions-for-building-akcl < prev    next >
Lisp/Scheme  |  1992-06-08  |  6KB  |  183 lines

  1. This file contains instructions for building akcl-1-615, and also contains
  2. instructions on how to build PCL,CLCS,CLX,an inspecter,CLUE, and CLIO in akcl.
  3.  
  4. #Let top be the directory that will contain the directories kcl,akcl-1-615, and systems
  5. cd whatever-top-should-be
  6. set top = `pwd`
  7. cd top
  8. #get kcl.tar.Z and akcl-1-615.tar.Z from rascal.ics.utexas.edu:pub.
  9. mkdir kcl
  10. cd kcl
  11. zcat ../kcl.tar | tar xf -
  12. cd ..
  13. mkdir akcl-1-615
  14. cd akcl-1-615
  15. zcat ../akcl-1-615.tar.Z | tar xf -
  16. #optional: edit h/sun4.defs, so that it uses gcc instead (maybe remove -g to save space)
  17. #          you can change the refrence to gcc to (something like) /usr/local/gnu/bin/gcc
  18. #          don't change the as, though, or if you do, make it /bin/as
  19. add-defs sun4 $top/kcl
  20. make -f Smakefile
  21. #let it run until it stops.
  22. #If it worked, skip this:
  23. -----------------------------------------------------------------
  24. #If it stops with an error while creating raw_kcl, do
  25. rm unixport/raw_kcl
  26. #There is some problem with gcc or the gnu linker that causes an error related
  27. #to the c files that are initially linked to ../lsp/dummy.c.
  28. #If you have previously created a recent version of akcl, you can do:
  29. #  cp -p OLD/unixport/saved_kcl unixport/saved_kcl
  30. #  make -f Smakefile
  31. #and skip the rest of this step.
  32. #Otherwise, do
  33. cp -p unixport/makefile unixport/makefile.save
  34. #  edit unixport/makefile, changing the definitions of LSPOBJS and CMPOBJS to:
  35. LSPOBJS    = $(LSPDIR)/assert.o $(LSPDIR)/describe.o $(LSPDIR)/evalmacros.o \
  36.     $(LSPDIR)/iolib.o $(LSPDIR)/listlib.o $(LSPDIR)/mislib.o \
  37.     $(LSPDIR)/module.o $(LSPDIR)/numlib.o $(LSPDIR)/seq.o \
  38.     $(LSPDIR)/seqlib.o $(LSPDIR)/top.o $(LSPDIR)/trace.o
  39.  
  40. CMPOBJS    = $(CMPDIR)/cmpbind.o $(CMPDIR)/cmpcatch.o $(CMPDIR)/cmpif.o \
  41.     $(CMPDIR)/cmplet.o $(CMPDIR)/cmpmap.o $(CMPDIR)/cmpmulti.o
  42. #next, do:
  43. cd unixport
  44. make
  45. #when that finishes, do:
  46. mv makefile makefile.temp
  47. mv makefile.save makefile
  48. cd ..
  49. make -f Smakefile
  50. -----------------------------------------------------------------
  51. #gcc apparently does not compile c/main.c correctly: 
  52. #  segmentation violations cause kcl to die.
  53. #if you did not use gcc, skip this step.
  54.  
  55. #edit h/sun4.defs, commenting out the gcc line and uncommenting the cc line
  56. add-defs sun4 `top`/kcl
  57. make -f Smakefile sources
  58. cd o
  59. rm main.o
  60. make
  61. cd ..
  62. #edit h/sun4.defs, uncommenting the gcc line and commenting the cc line
  63. add-defs sun4 $top/kcl
  64. make -f Smakefile
  65. -----------------------------------------------------------------
  66. The next six changes are optional (but if you do any of the
  67. second through sixth changes, you should do them all):
  68. -   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -
  69. lsp/top.lsp: make the first catch form in top-level be:
  70.     (catch *quit-tag*
  71.       (cond (*multiply-stacks* (setq *multiply-stacks* nil))
  72.         ((dotimes (i (si:argc) t)
  73.            (when (equal (si:argv i) "-noinit")
  74.          (return nil)))
  75.          (let ((tem (string-concatenate *system-directory*
  76.                      "sys-init.lsp")))
  77.            (when (probe-file tem)
  78.          (load tem :verbose nil)))
  79.          (let ((home (or (getenv "HOME") "")))
  80.            (cond ((probe-file (format nil "~a/lisp-init.lisp" home))
  81.               (load (format nil "~a/lisp-init.lisp" home)))))))
  82.       (and (functionp *top-level-hook*)(funcall *top-level-hook*)))
  83.  
  84. c/file.d: change:
  85.     LSP_string = make_simple_string("lsp");
  86. to:
  87.     LSP_string = make_simple_string("lisp");
  88.  
  89. cmpnew/cmpmain.lsp:
  90. change the line:
  91.         (setq gaz (get-output-pathname gaz "lsp" (car args)))
  92. to:
  93.         (setq gaz (get-output-pathname gaz "lisp" (car args)))
  94. and change every occurrence of #".lsp" to #".lisp"
  95. -- do not change the lsp to lisp for the loads of "./cmpinit.lsp"!
  96.  
  97. V/makefile: change the second line after the command: step.
  98. From:
  99. command:
  100.     (cd $(PORTDIR); rm -f ../xbin/akcl ; echo "#!/bin/sh" > ../xbin/akcl; \
  101.     echo "`pwd`/saved_kcl `pwd`/" >> ../xbin/akcl)
  102. To:
  103. command:
  104.     (cd $(PORTDIR); rm -f ../xbin/akcl ; echo "#!/bin/sh" > ../xbin/akcl; \
  105.     echo "`pwd`/saved_kcl `pwd`/ \$${*}">> ../xbin/akcl)
  106.  
  107. V/lsp/makefile:
  108. From:
  109. .lsp.c: 
  110.     @ ../xbin/if-exists $(PORTDIR)/saved_kcl \
  111.     "rm -f $*.c $*.h $*.data $*.o" \
  112.     "$(PORTDIR)/saved_kcl $(PORTDIR)/ $* $* S0111"
  113.  
  114. .lsp.o: 
  115.     @ ../xbin/if-exists $(PORTDIR)/saved_kcl \
  116.     "rm -f $*.c $*.h $*.data $*.o" \
  117.     "$(PORTDIR)/saved_kcl $(PORTDIR)/ $* $* S0111" \
  118. To:
  119. .lsp.c: 
  120.     @ ../xbin/if-exists $(PORTDIR)/saved_kcl \
  121.     "rm -f $*.c $*.h $*.data $*.o" \
  122.     "$(PORTDIR)/saved_kcl $(PORTDIR)/ $*.lsp $*.o S0111"
  123.  
  124. .lsp.o: 
  125.     @ ../xbin/if-exists $(PORTDIR)/saved_kcl \
  126.     "rm -f $*.c $*.h $*.data $*.o" \
  127.     "$(PORTDIR)/saved_kcl $(PORTDIR)/ $*.lsp $*.o S0111" \
  128.  
  129. V/cmpnew/makefile:
  130. From:
  131. @s|    @ ../xbin/if-exists $(PORTDIR)/saved_kcl \
  132.     "rm -f $*.c $*.h $*.data $*.o" \
  133.     "$(PORTDIR)/saved_kcl $(PORTDIR)/ $* $* S0111"
  134. To:
  135. @s|    @ ../xbin/if-exists $(PORTDIR)/saved_kcl \
  136.     "rm -f $*.c $*.h $*.data $*.o" \
  137.     "$(PORTDIR)/saved_kcl $(PORTDIR)/ $*.lsp $*.o S0111"
  138. and From:
  139. .lsp.o:
  140.     @ ../xbin/if-exists $(PORTDIR)/saved_kcl \
  141.     "rm -f $*.c $*.h $*.data $*.o" \
  142.     "$(PORTDIR)/saved_kcl $(PORTDIR)/ $* $* S0111" \
  143. To:
  144. .lsp.o:
  145.     @ ../xbin/if-exists $(PORTDIR)/saved_kcl \
  146.     "rm -f $*.c $*.h $*.data $*.o" \
  147.     "$(PORTDIR)/saved_kcl $(PORTDIR)/ $*.lsp $*.o S0111" \
  148.  
  149. -   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -
  150. Fix bad calls to FEerror in the c directory:
  151. #do:
  152. cd c
  153. etags *.*
  154. cd ..
  155. #and then, in emacs, visit that tags table (m-x visit-tags-table)
  156. #and do m-x tags-search FEerror(
  157. #and make sure every call to FEerror has at least two args.
  158. #for example, change:
  159. FEerror("bad rb_end");
  160. #to
  161. FEerror("bad rb_end",0);
  162. #Use m-, to go to the next occurrence; 
  163. #if you need to change the call, use c-m-f ,0
  164. #change every call that needs it.
  165. #There are several occurences of calls to FEerror where there
  166. #is a number first, then a string.  Be sure to switch the first two args
  167. #in those cases.
  168.  
  169.  
  170. #then do
  171. make -f Smakefile
  172. #again.
  173. =================================================================================
  174.  
  175. cd top
  176. #get March-92-systems.tar.Z and clue-and-clio.tar.Z from parcftp.xerox.com:pub/pcl
  177. mkdir systems
  178. cd systems
  179. zcat March-92-systems.tar.Z | tar xf -
  180. zcat clue-and-clio.tar.Z | tar xf -
  181. #edit the first two lines of the file makefile (and possibly the next two lines).
  182. make
  183.